package com.glorystone.ins.service;

import com.glorystone.ins.domain.Attachment;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;

/**
 * Created by wangwei on 2018/3/20.
 */
public interface AttachmentService {

    Attachment findById(Long tid);

    void save(MultipartFile[] files, Integer[] types, String[] alias, Attachment.BusinessTypeEnum businessTypeEnum, Long businessId);

    void save(MultipartFile file, Integer type, String alias, Attachment.BusinessTypeEnum businessTypeEnum, Long businessId);


    List<Attachment> queryAttachList(Long businessId, int businessType);

    void update(MultipartFile file, Integer type, String alias, Attachment.BusinessTypeEnum businessTypeEnum, Long businessId);

    void update(MultipartFile[] files, Integer[] types, String[] alias, Attachment.BusinessTypeEnum businessTypeEnum, Long businessId);

    void delete(Long attachmentId);
}
